package Assignment;

import java.util.Scanner;

public class Test4 {
    public static void main(String[] args) {

        Scanner scanner = new Scanner(System.in);
        System.out.println("是否为会员：（0表示普通顾客，1表示会员）");
        int vip = scanner.nextInt();

        System.out.println("输入购物金额：");
        double money = scanner.nextDouble();

        if (vip == 1 && money > 0) {
            //会员用户
            if (money >= 200) {
                money *= 0.75;
                System.out.println("应付金额为："+money);
            } else {
                money *= 0.8;
                System.out.println("应付金额为："+money);
            }
        } else if (vip == 0 && money > 0) {
            //普通用户
            if (money >= 100) {
                money *= 0.9;
                System.out.println("应付金额为："+money);
            }
        } else {
            System.out.println("请输入正确的信息！");
        }


    }
}
